//
//  LBTableViewItem.h
//  jslj
//
//  Created by LINAICAI on 2017/9/29.
//  Copyright © 2017年 广东联结电子商务有限公司. All rights reserved.
//

#import <Foundation/Foundation.h>
//传递不同类型的cell
typedef NS_OPTIONS(NSUInteger, LBCellItemBuilderStyle) {
    LBCellItemBuilderStyleNone = 1 << 0,//什么都没有
    LBCellItemBuilderStyleArrow = 1 << 1,//只有箭头
    LBCellItemBuilderStyleBadge = 1 << 2,//只有红点
    LBCellItemBuilderStyleString= 1 << 3,//只有标签文本
    LBCellItemBuilderStyleCustomView= 1 << 4,//只有一个自由定义的视图
};

@interface LBCellItemBuilder : NSObject
@property (nonatomic , copy ,readonly)NSString *title;
@property (nonatomic , copy ,readonly)UIImage *image;
@property (nonatomic , assign ,readonly)LBCellItemBuilderStyle style;//类型
@property (nonatomic , copy ,readonly)id attachedField;//附加字段，针对不同类型的附加字段不一样
@property (nonatomic , copy ,readonly)void(^action)(void) ;

- (instancetype)initWithTitle:(NSString *)title
                        image:(UIImage *)image
                        style:(LBCellItemBuilderStyle)style
                attachedField:(id)attachedField
                       action:(void(^)(void))action;

- (instancetype)initWithTitle:(NSString *)title
                        style:(LBCellItemBuilderStyle)style
                attachedField:(id)attachedField
                       action:(void(^)(void))action;

- (instancetype)initWithTitle:(NSString *)title
                        image:(UIImage *)image
                        style:(LBCellItemBuilderStyle)style
                       action:(void(^)(void))action;

- (instancetype)initWithTitle:(NSString *)title
                        style:(LBCellItemBuilderStyle)style
                       action:(void(^)(void))action;

@end
